Input sensitivity of a comparator is determined based on an offset, a hysteresis characteristic, and the like. If the offset is not provided and the difference between two voltages input to the comparator is 0 V, a logic level of a voltage output from the comparator is reversed from a high (H) level to a low (L) level or from the L level to the H level. However, if the offset is provided and the difference between the input voltages is 0 V, the logic level of the voltage output from the comparator is not reversed. If the offset is provided and the difference is a positive or negative value (hereinafter referred to as offset amount), the logic level of the output voltage is reversed.
The hysteresis characteristic is a characteristic in which the difference between the input voltages when the logic level of the output voltage is changed from the H level to the L level is different from the difference between the input voltages when the logic level of the output voltage is changed from the L level to the H level. The hysteresis characteristic occurs when the comparator is not completely reset or the like. Hereinafter, the difference between the difference between input voltages when a logic level of an output voltage is changed from an H level to an L level and the difference between the input voltages when the logic level of the output voltage is changed from the L level to the H level is referred to as a hysteresis amount.
In order to increase the input sensitivity of the comparator, it is considered that the offset amount and the hysteresis amount are reduced. However, there are a case where the offset amount is set as a reference value of the comparator and a case where the hysteresis amount is set to a certain value as measures against noise.
Japanese Laid-open Patent Publications Nos. 2011-151452 and 5-63527 are examples of related art.
In order to detect the hysteresis characteristic, it is considered that the amplitude of an analog voltage to be input to the comparator is changed, a point at which the logic level of the output voltage is reversed is found by an analog measurer, and the hysteresis amount is calculated. This method, however, is cumbersome.